package com.yuke.cloud.service.pmc.dao;

import com.yuke.cloud.common.core.mybatis.MyMapper;
import com.yuke.cloud.service.api.pmc.dto.ProdSpecInfoDto;
import com.yuke.cloud.service.pmc.dto.*;
import com.yuke.cloud.service.pmc.entity.ProdProduct;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface ProdProductMapper extends MyMapper<ProdProduct> {
    List<Long> getSpecIdByCategoryId(Long categoryId);
    List<ProdSpecInfoAndPriceDto> getSpecInfoByRegionId(Long regionId);
    List<ProdProduct> getListByCondition(@Param("prodProduct") ProdProduct prodProduct);
    List<ProdProductInfoDto> getListsByCondition(@Param("list") List<Long> leafCategoryIds, @Param("conditionDto") ConditionDto conditionDto);
    ProdSpecByCategoryDto getSpecBySpecId(Long categoryId);
    List<Long> getSpecIdsByRegionId(Long regionId);
    List<ProdSpecInfoAndPriceDto> ProdSpecInfoAndPriceByCategoryIds(List<Long> categoryIds);
    ProdProduct selectProductByProductId(Long productId);
    List<ProdSpecDto> getProdSpecsByProductId(Long productId);
    //api
    List<ProdSpecInfoDto> getProdNameByProductId(@Param("list") List<Long> productIds);
    void deleteByProductId(Long productId);
}